Skip to content

Conversation

@Dishank-Sen
Copy link
Contributor

@Dishank-Sen Dishank-Sen commented Sep 23, 2025

PR Title

πŸ› Fix adaptor.FiberApp to handle Unix sockets + βœ… add unit test

Description

This PR fixes a bug in adaptor.FiberApp that caused requests over Unix domain sockets to return a 500 Internal Server Error.

The issue was due to improper handling of RemoteAddr for Unix socket connections. A fallback mechanism has been added to correctly handle requests via Unix sockets.

Additionally, a new unit test has been added to validate Unix socket support.

Changes introduced

  • Fixed adaptor.FiberApp to properly handle RemoteAddr for Unix socket requests.
  • Added unixsocket_test.go to validate Unix domain socket functionality.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improvement to existing functionality)
  • Test addition (new unit test for Unix socket support)

Checklist

  • Self-reviewed the code and added comments where necessary.
  • Added unit test for Unix socket support.
  • Verified all unit tests pass locally.
  • Ensured no unnecessary dependencies were introduced.

Fixes #3751

@Dishank-Sen Dishank-Sen requested a review from a team as a code owner September 23, 2025 08:55
@welcome
Copy link

welcome bot commented Sep 23, 2025

Thanks for opening this pull request! πŸŽ‰ Please check out our contributing guidelines. If you need help or want to chat with us, join us on Discord https://gofiber.io/discord

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 23, 2025

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Walkthrough

Adds helpers to normalize and resolve remote addresses (including Unix domain sockets) in the adaptor, replaces inline port-fix logic with the new resolver, and adds tests for Unix socket handling and malformed RemoteAddr fallback.

Changes

Cohort / File(s) Summary
Adaptor remote address handling
middleware/adaptor/adaptor.go
Add isUnixNetwork(network string) bool and resolveRemoteAddr(remoteAddr string, localAddr any) (net.Addr, error); replace inline port-fix and direct net.ResolveTCPAddr usage with resolveRemoteAddr(...); on resolution failure set remoteAddr = nil so fasthttp handles it.
Unix socket and fallback tests
middleware/adaptor/adaptor_test.go
Add TestUnixSocketAdaptor and TestHandlerFunc_FallbackRemoteAddr; import os, path/filepath, time; include Unix socket setup/cleanup and a test exercising fallback when RemoteAddr is malformed.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  participant Client
  participant NetHTTP as "net/http Server"
  participant Adaptor
  participant Fasthttp as "fasthttp app"

  Client->>NetHTTP: HTTP request (TCP or Unix socket)
  NetHTTP->>Adaptor: forward http.Request (RemoteAddr, LocalAddrContextKey)
  Adaptor->>Adaptor: resolveRemoteAddr(RemoteAddr, LocalAddrContextKey)
  alt Resolved to TCP addr
    Adaptor->>Fasthttp: forward request with resolved TCP remoteAddr
  else Unix socket or unresolved
    Note right of Adaptor #E8F8F5: set remoteAddr = nil (fallback)
    Adaptor->>Fasthttp: forward request without TCP remoteAddr
  end
  Fasthttp-->>Adaptor: response
  Adaptor-->>NetHTTP: http.Response
  NetHTTP-->>Client: HTTP/1.1 response
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Suggested reviewers

  • gaby
  • sixcolors
  • efectn

Poem

I hopped through sockets, soft and quick,
Ports sometimes missing β€” I fixed that trick.
Unix paths whispered, I learned their name,
I left a gentle nil and let fasthttp claim.
Now requests bounce back, and I nibbled the bug. πŸ‡

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
βœ… Passed checks (4 passed)
Check name Status Explanation
Title Check βœ… Passed The title clearly focuses on the core change of handling Unix sockets within the adaptor middleware and directly reflects the bug fix addressed in this pull request while remaining concise and specific enough for teammates to understand the primary update.
Linked Issues Check βœ… Passed The implemented resolveRemoteAddr helper and updated handler logic directly address the improper RemoteAddr handling for Unix domain sockets specified in issue #3751, and the added unit tests verify both Unix socket support and fallback behavior, fully satisfying the linked issue’s objectives.
Out of Scope Changes Check βœ… Passed All modifications, including the private helpers in adaptor.go and the addition of related unit tests, align closely with the goal of supporting Unix sockets in the adaptor middleware and do not introduce unrelated or extraneous changes beyond the scope of issue #3751.
Description Check βœ… Passed The PR description follows the repository template by providing a clear summary of the bug fix and its purpose, listing the specific changes introduced, categorizing the type of change, including the required checklist, and referencing the fixed issue with β€œFixes #3751,” covering the essential template sections.
✨ Finishing touches
  • πŸ“ Generate Docstrings
πŸ§ͺ Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

πŸ“œ Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 8fbb9aa and f235a7b.

πŸ“’ Files selected for processing (1)
  • middleware/adaptor/adaptor_test.go (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • middleware/adaptor/adaptor_test.go

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❀️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @Dishank-Sen, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request resolves a critical bug in the adaptor.FiberApp that led to "500 Internal Server Error" responses when processing requests originating from Unix domain sockets. The fix involves enhancing the RemoteAddr handling logic to gracefully manage Unix socket connections, ensuring they are processed correctly. A new, comprehensive unit test has been introduced to confirm the efficacy of this fix and establish robust test coverage for Unix socket interactions.

Highlights

  • Unix Socket Handling: Corrected a bug in adaptor.FiberApp that previously caused "500 Internal Server Error" for requests made over Unix domain sockets by implementing a proper fallback for RemoteAddr resolution.
  • Test Coverage: Added a new unit test, TestUnixSocketAdaptor, to specifically validate the correct functionality of Unix domain socket support within the adaptor.FiberApp.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with πŸ‘ and πŸ‘Ž on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request correctly fixes an issue where requests over Unix domain sockets would fail. The change in adaptor.go properly handles RemoteAddr for non-TCP connections by falling back to a nil address, which fasthttp can handle. The newly added test in adaptor_test.go provides good coverage for this scenario. I have a couple of suggestions to make the new test more robust and isolated.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (4)
middleware/adaptor/adaptor_test.go (3)

704-716: Use test logging instead of printing to stdout.

Replace fmt.Println with t.Logf to keep test output clean.

 	// Read response
 	buf := make([]byte, 1024)
 	n, err := conn.Read(buf)
 	if err != nil {
 		listener.Close()
 		t.Fatal(err)
 	}
 
 	rawResponse := string(buf[:n])
-	fmt.Println("Raw response:\n", rawResponse)
+	t.Logf("Raw response:\n%s", rawResponse)

695-702: Consider a bounded dial to avoid hangs.

Use net.DialTimeout with a short timeout to prevent a stuck read if the server doesn’t accept in time.

Example:

conn, err := net.DialTimeout("unix", socketPath, 2*time.Second)

Requires: import "time"


717-721: Assert status code too, not only body substring.

A quick check avoids false positives if body changes.

if !strings.HasPrefix(rawResponse, "HTTP/1.1 200") {
	t.Fatalf("unexpected status line: %q", rawResponse)
}
middleware/adaptor/adaptor.go (1)

171-179: Solid Unix-socket fallback; simplify and avoid err shadowing.

Current logic is correct. You can simplify and make the intent clearer by using net.Addr directly and a separate tcpErr variable.

Please confirm fasthttp.RequestCtx.Init tolerates a nil remoteAddr across the supported fasthttp versions in this repo.

-		// Determine remoteAddr for TCP or fallback for Unix sockets
-		var remoteAddr *net.TCPAddr
-		tcpAddr, err := net.ResolveTCPAddr("tcp", r.RemoteAddr)
-		if err != nil {
-			// Unix socket or invalid address
-			remoteAddr = nil // fasthttp will handle nil correctly
-		} else {
-			remoteAddr = tcpAddr
-		}
+		// Determine remoteAddr for TCP or fallback for Unix sockets
+		var remoteAddr net.Addr // nil => fasthttp handles it
+		if addr, tcpErr := net.ResolveTCPAddr("tcp", r.RemoteAddr); tcpErr == nil {
+			remoteAddr = addr
+		}
πŸ“œ Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between edb585b and 5d942ea.

πŸ“’ Files selected for processing (2)
  • middleware/adaptor/adaptor.go (1 hunks)
  • middleware/adaptor/adaptor_test.go (2 hunks)
🧰 Additional context used
πŸ““ Path-based instructions (1)
**/*.go

πŸ“„ CodeRabbit inference engine (AGENTS.md)

**/*.go: Format Go code using gofumpt (enforced via make format)
Ensure code passes golangci-lint checks (enforced via make lint)
Optimize struct field alignment using betteralign (enforced via make betteralign)
Modernize Go code using gopls modernize (enforced via make modernize)

Files:

  • middleware/adaptor/adaptor.go
  • middleware/adaptor/adaptor_test.go
🧠 Learnings (1)
πŸ“š Learning: 2024-11-10T23:44:13.704Z
Learnt from: gaby
PR: gofiber/fiber#3193
File: middleware/adaptor/adaptor.go:111-111
Timestamp: 2024-11-10T23:44:13.704Z
Learning: In the `middleware/adaptor/adaptor.go` file of the Fiber framework, when updating context handling, replacing `c.Context()` with `c.RequestCtx()` is appropriate to access the `fasthttp.RequestCtx`.

Applied to files:

  • middleware/adaptor/adaptor.go
🧬 Code graph analysis (1)
middleware/adaptor/adaptor_test.go (1)
middleware/adaptor/adaptor.go (1)
  • FiberApp (137-139)

@gaby gaby added this to v3 Sep 23, 2025
@gaby gaby added this to the v3 milestone Sep 23, 2025
@gaby gaby moved this to In Progress in v3 Sep 23, 2025
@gaby gaby changed the title fix(adaptor): handle Unix sockets correctly & add test coverage πŸ› bug: Handle Unix sockets in adaptor middleware Sep 23, 2025
@codecov
Copy link

codecov bot commented Sep 23, 2025

Codecov Report

❌ Patch coverage is 95.45455% with 1 line in your changes missing coverage. Please review.
βœ… Project coverage is 91.54%. Comparing base (cd273d2) to head (f235a7b).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
middleware/adaptor/adaptor.go 95.45% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3760      +/-   ##
==========================================
+ Coverage   91.50%   91.54%   +0.03%     
==========================================
  Files         113      113              
  Lines       11896    11912      +16     
==========================================
+ Hits        10886    10905      +19     
+ Misses        742      740       -2     
+ Partials      268      267       -1     
Flag Coverage Ξ”
unittests 91.54% <95.45%> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

β˜” View full report in Codecov by Sentry.
πŸ“’ Have feedback on the report? Share it here.

πŸš€ New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
middleware/adaptor/adaptor_test.go (2)

699-705: Guarantee server shutdown even on early failures via t.Cleanup.

This makes teardown robust and avoids relying on manual closes sprinkled across error paths.

Apply this diff:

 done := make(chan struct{})
 go func() {
   if err := http.Serve(listener, handler); err != nil && err != http.ErrServerClosed {
     t.Errorf("http.Serve failed: %v", err)
   }
   close(done)
 }()
+ t.Cleanup(func() {
+   _ = listener.Close()
+   <-done
+ })

Optional: once this is added, you can remove the explicit listener.Close() and <-done at Lines 744-746.


707-718: Set a connection deadline to prevent hangs/flakes.

Without a deadline, a stalled read/write can hang the test. Add a short deadline.

Apply this diff:

 conn, err := net.Dial("unix", socketPath)
 if err != nil {
   if err := listener.Close(); err != nil {
     t.Errorf("listener.Close failed: %v", err)
   }
   t.Fatal(err)
 }
 defer func() {
   if err := conn.Close(); err != nil {
     t.Errorf("conn.Close failed: %v", err)
   }
 }()
+ // avoid indefinite hangs on read/write
+ require.NoError(t, conn.SetDeadline(time.Now().Add(5*time.Second)))

And add the missing import:

 import (
   "bytes"
   "context"
   "fmt"
   "io"
   "net"
   "net/http"
   "net/http/httptest"
   "net/url"
   "os"
   "path/filepath"
   "runtime"
+  "time"
   "strings"
   "testing"
πŸ“œ Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 599bd4c and 45af477.

πŸ“’ Files selected for processing (1)
  • middleware/adaptor/adaptor_test.go (2 hunks)
🧰 Additional context used
πŸ““ Path-based instructions (1)
**/*.go

πŸ“„ CodeRabbit inference engine (AGENTS.md)

**/*.go: Format Go code using gofumpt (enforced via make format)
Ensure code passes golangci-lint checks (enforced via make lint)
Optimize struct field alignment using betteralign (enforced via make betteralign)
Modernize Go code using gopls modernize (enforced via make modernize)

Files:

  • middleware/adaptor/adaptor_test.go
🧬 Code graph analysis (1)
middleware/adaptor/adaptor_test.go (1)
middleware/adaptor/adaptor.go (1)
  • FiberApp (137-139)

@gaby
Copy link
Member

gaby commented Sep 26, 2025

/gemini review

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request correctly fixes a bug that prevented the adaptor middleware from handling requests over Unix domain sockets. The change in adaptor.go is sound, and the new unit test in adaptor_test.go provides excellent coverage for this functionality. I've included one suggestion to refactor the new test for improved robustness and code clarity. Overall, this is a solid contribution.

@Dishank-Sen
Copy link
Contributor Author

@gaby All tests are passing on this PR. Just wanted to kindly ask if there’s anything else needed from my side to move this forward, or if it’s ready for review/merge. Thanks for your time .

@gaby
Copy link
Member

gaby commented Sep 27, 2025

@Dishank-Sen Will merge this today

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
middleware/adaptor/adaptor.go (1)

197-205: Remove unsafe SplitHostPort type-assert; rely on resolveRemoteAddr

Drop the pre-mutation of r.RemoteAddr: resolveRemoteAddr already handles missing ports and avoids a panic on non-AddrError.

-		if _, _, err := net.SplitHostPort(r.RemoteAddr); err != nil && err.(*net.AddrError).Err == "missing port in address" { //nolint:errorlint,forcetypeassert,errcheck
-			r.RemoteAddr = net.JoinHostPort(r.RemoteAddr, "80")
-		}
-
-		remoteAddr, err := resolveRemoteAddr(r.RemoteAddr, r.Context().Value(http.LocalAddrContextKey))
+		remoteAddr, err := resolveRemoteAddr(r.RemoteAddr, r.Context().Value(http.LocalAddrContextKey))
🧹 Nitpick comments (2)
middleware/adaptor/adaptor.go (2)

142-149: Solid Unix-network detection; one-line simplification possible

The switch works. Tiny nit: a single return reads cleaner.

-func isUnixNetwork(network string) bool {
-	switch network {
-		case "unix", "unixgram", "unixpacket":
-			return true
-		default:
-			return false
-	}
-}
+func isUnixNetwork(network string) bool {
+	return network == "unix" || network == "unixgram" || network == "unixpacket"
+}

152-156: Avoid re-parsing Unix addrs; return the existing addr

If LocalAddrContextKey is a Unix addr, you can return it directly instead of creating a new one from String(); this avoids odd β€œunix:…” names and unnecessary work.

-func resolveRemoteAddr(remoteAddr string, localAddr any) (net.Addr, error) {
-	if addr, ok := localAddr.(net.Addr); ok && isUnixNetwork(addr.Network()) {
-		return net.ResolveUnixAddr("unix", addr.String())
-	}
+func resolveRemoteAddr(remoteAddr string, localAddr any) (net.Addr, error) {
+	if addr, ok := localAddr.(net.Addr); ok && isUnixNetwork(addr.Network()) {
+		// Pass through the Unix addr as-is.
+		return addr, nil
+	}
πŸ“œ Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

πŸ“₯ Commits

Reviewing files that changed from the base of the PR and between 43e5f82 and 896afbd.

πŸ“’ Files selected for processing (1)
  • middleware/adaptor/adaptor.go (3 hunks)
🧰 Additional context used
πŸ““ Path-based instructions (1)
**/*.go

πŸ“„ CodeRabbit inference engine (AGENTS.md)

**/*.go: Format Go code using gofumpt (enforced via make format)
Ensure code passes golangci-lint checks (enforced via make lint)
Optimize struct field alignment using betteralign (enforced via make betteralign)
Modernize Go code using gopls modernize (enforced via make modernize)

Files:

  • middleware/adaptor/adaptor.go
🧠 Learnings (1)
πŸ“š Learning: 2024-11-10T23:44:13.704Z
Learnt from: gaby
PR: gofiber/fiber#3193
File: middleware/adaptor/adaptor.go:111-111
Timestamp: 2024-11-10T23:44:13.704Z
Learning: In the `middleware/adaptor/adaptor.go` file of the Fiber framework, when updating context handling, replacing `c.Context()` with `c.RequestCtx()` is appropriate to access the `fasthttp.RequestCtx`.

Applied to files:

  • middleware/adaptor/adaptor.go
πŸ”‡ Additional comments (1)
middleware/adaptor/adaptor.go (1)

201-205: Good fallback for Unix sockets

Gracefully defaulting to nil remoteAddr lets fasthttp proceed without a 500 on Unix sockets. Nice.

Comment on lines 157 to 166
resolved, err := net.ResolveTCPAddr("tcp", remoteAddr)
if err == nil {
return resolved, nil
}

var addrErr *net.AddrError
if errors.As(err, &addrErr) && addrErr.Err == "missing port in address" {
remoteAddr = net.JoinHostPort(remoteAddr, "80")
return net.ResolveTCPAddr("tcp", remoteAddr)
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

πŸ› οΈ Refactor suggestion | 🟠 Major

Missing-port handling is robust here

Good use of errors.As and fallback to :80. Recommend consolidating on this path and deleting the older SplitHostPort/type-assert block below to avoid duplication and unsafe casts.

πŸ€– Prompt for AI Agents
In middleware/adaptor/adaptor.go around lines 157 to 166, the new
errors.As-based missing-port handling correctly falls back to port 80; remove
the older SplitHostPort/type-assert block further down (the duplicated logic
that uses net.SplitHostPort and unsafe type assertions) so there is a single,
robust path for handling addresses missing a port; ensure no remaining
references to the deleted variables or casts remain and that net.ResolveTCPAddr
is used consistently for both the normal and fallback cases.

Copy link
Member

@sixcolors sixcolors left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Dishank-Sen! I noticed there were some test coverage gaps and also there is a potential panic issue in the CopyContextToFiberContext function (outside of the diff range). I've been working on some improvements locally - would you be interested in collaborating? I can either:

  1. Share the fixes with you so you can add them to your branch
  2. Create a separate follow-up PR after yours is merged
  3. Help you implement the fixes or commit them to this branch

What would work best for you?

@Dishank-Sen
Copy link
Contributor Author

@sixcolors I’d be happy to collaborate. Feel free to share the fixes and I’ll add them, or open a follow-up PR β€” whichever you prefer.

@sixcolors
Copy link
Member

unix-socket-improvements.patch

Was before 4d25336, but contained coverage that it included as well as coverage for other missing lines outside of the diff range.

Copy link
Member

@sixcolors sixcolors left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved. If the suggestions in the patch aren’t adopted, I’ll create a follow-on PR and tag @Dishank-Sen for review.

@gaby
Copy link
Member

gaby commented Sep 28, 2025

@Dishank-Sen Did you apply the changes from @sixcolors patch?

@Dishank-Sen
Copy link
Contributor Author

@gaby As of my last commit, I haven’t applied the changes from @sixcolors’ patch yet.

@ReneWerner87 ReneWerner87 merged commit 1fe34cd into gofiber:main Sep 29, 2025
15 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in v3 Sep 29, 2025
@welcome
Copy link

welcome bot commented Sep 29, 2025

Congrats on merging your first pull request! πŸŽ‰ We here at Fiber are proud of you! If you need help or want to chat with us, join us on Discord https://gofiber.io/discord

Abhirup-99 pushed a commit to Abhirup-99/fiber that referenced this pull request Nov 3, 2025
* Fix Fiber v3 adapter for Unix socket testing

* test(adaptor): use temp dir for Unix socket and skip on non-Unix

* formatted test file and handle error check

* resolves issues in adapter test

* *net.TCPaddr to net.addr

* fixes in adaptor test

* fixes in adaptor test

* fixes in adaptor test

* checked error return in adataptor test

* resolved variable shadowing in adaptor test

* resolved variable shadowing in adaptor test

* resolved variable shadowing in adaptor test

* added resolveRemoteAddr function for resolving addr properly

* changes in resolveRemoteAddr function

* resolved lint error

* added test for bad remote address

* resolve lint issue in adaptor test

* resolve lint issue in adaptor test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

πŸ› [Bug]: Unix domain socket with Adaptor gives Internal Server Error

4 participants